package com.uplooking.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import com.alibaba.fastjson.JSONObject;
import com.uplooking.service.DictService;

@Controller
public class DictController {

	@Autowired
	private DictService dictService;

	@ResponseBody
	@RequestMapping(value = "/dict/list", method = RequestMethod.GET, produces = { "application/json;charset=utf-8" })
	public String methodDictList(int tid) throws Exception {
		return JSONObject.toJSONString(dictService.getDictListById(tid));
	}	

}
